package com.iotboss.common.mapper.mysql;

import com.iotboss.common.core.domain.entity.SysUser;
import org.apache.ibatis.annotations.Mapper;

@Mapper
public interface UserMapper {
    /**
     * 根据openid查询用户
     * @param openId
     * @return
     */
    SysUser findUserByOpenId(String openId);


    /**
     * 注册新用户
     * @param user
     */
    void save(SysUser user);

    /**
     * 根据用户id查用户
     * @param id
     * @return
     */
    SysUser findUserById(Long id);
}
